import {
	request
} from "../indexsd.js"
export function Logins(data) {
	let {
		stast
	} = data
	// console.log(stast,"111111")
	if (stast == 'login') {
		return request({
			url: `/login`,
			method: 'post',
			data
		})
	}
	if (stast == 'register') {
		return request({
			url: `/register`,
			method: 'post',
			data
		})
	}
	if (stast == 'forget') {
		return request({
			url: `/reset_password`,
			method: 'post',
			data
		})
	}
}

export function getCode(data) {
	return request({
		url: '/send_sms',
		method: 'post',
		data
	})
}


export function login(data) {
	return request({
		url: '/sms_login',
		method: 'post',
		data
	})
}
export default {
	Logins,
	getCode,
	login
}